<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <!-- <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Product_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-product_id" data-rule="required" data-source="product/index" class="form-control selectpage" name="row[product_id]" type="text" value="">
        </div>
    </div> -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Plan_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-plan_id" data-rule="required" data-params='{"custom[status]":"normal"}'   data-source="clothmaking_plan/index"   data-field="id"  data-format-item="{id} - {product_name}"   class="form-control selectpage" name="row[plan_id]" type="text" value="">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Num')}:</label>
        <div class="col-xs-12 col-sm-8 location-relative">
            <input id="c-num" data-rule="required" class="form-control" step="0.01" name="row[num]" type="number">
            <span class="location-absolute">m²</span>
            
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Stock_type')}:</label>
        <div class="col-xs-12 col-sm-8">      
            <select  id="c-stock_type" data-rule="required" class="form-control selectpicker" name="row[stock_type]">
                {foreach name="stockTypeList" item="vo"}
                    <option value="{$key}">{$vo}</option>
                {/foreach}
            </select>
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Stock_test')}:</label>
        <div class="col-xs-12 col-sm-8">      
            <input id="c-stock_test" 
                data-source="clothmaking_testing_new/selectpage" 
                data-field="id"              
                data-show-field="id"      
                data-format-item="{id}"   
                class="form-control selectpage" 
                name="row[stock_test_id]" 
                type="text"
                value="{$row.id}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Status')}:</label>
        <div class="col-xs-12 col-sm-8">
            
            <div class="radio">
            {foreach name="statusList" item="vo"} 
            <label for="row[status]-{$key}"><input id="row[status]-{$key}" name="row[status]" type="radio" value="{$key}" {in name="key" value="待审核"}checked{/in} /> {$vo}</label> 
            {/foreach}
            </div>

        </div>
    </div>
    <!-- <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('User_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-user_id" data-rule="required" data-source="user/user/index" data-field="nickname" class="form-control selectpage" name="row[user_id]" type="text" value="">
        </div>
    </div> -->
    <input type="hidden" name="row[user_id]" value="{$user_id}">
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Remarks')}:</label>
        <div class="col-xs-12 col-sm-8">
           
             <textarea id="c-remarks" class="form-control " rows="5" name="row[remarks]" cols="50"></textarea>
        </div>
    </div>
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-primary btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
<style>
    .location-relative {
        position: relative;
    }
    .location-absolute {
        position: absolute;
        top: 5px;
        right: 45px;
    }
</style>